<!DOCTYPE html>
<html lang="zh-CN">
    <head><meta charset='utf-8'>
<meta name='viewport' content='width=device-width, initial-scale=1'><meta name='description' content='hexo 官方主页：https://hexo.io/zh-cn/
基于nodejs，部分主题对nodejs版本要求比较高，安装包升级包容易出现兼容性问题；
最大的问题就是编译速度太慢了。超过1W的文件量，windows底下就直接报“too many open files”错误，在linux下编译也是小时级别的，无法忍受。
找到的合适的主题：https://github.com/blinkfox/hexo-theme-matery
本地实施目录： F:\study\js\hexo_html 临时对比目录 F:\study\js\hexo2html
关于配置文件
根目录的配置文件和主题目录的配置文件一同生效，并且如果有相同配置，是以主题目录的配置为主的。这点试了好多次才发现的规律
遇到的问题：文件明太长，git无法cp文件，（windows文件名有255的长度限制）
报错信息：
1  unable to stat “xxxxxxxxxxxxxxxxxxx/index.html” Filename too long   解决方法：https://confluence.atlassian.com/bamkb/git-checkouts-fail-on-windows-with-filename-too-long-error-unable-to-create-file-errors-867363792.html
1 2  git config --system core.longpaths true git config --global core.longpaths true   hugo 官网文档：https://gohugo.io/getting-started/quick-start/
合适的主题：https://themes.gohugo.io/themes/parsa-hugo/
​	：文档：https://docs.gethugothemes.com/parsa/?ref=github
 另一个参考的主题：https://themes.gohugo.io/themes/hugo-theme-dream/ （问题多，而且demo和文档都无法查到了）  本地实施并修改的目录：
cloudflare上部署的时候遇到版本太低的问题，用环境变量来指定版本。官方文档说明如下
  1  Hugobuildsautomaticallyrunanoldversion.TorunthelatestversionofHugo(forexample,`0.80.0`),youwillneedtosetanenvironmentvariable.Set`HUGO_VERSION`to`0.80.0`ortheHugoversionofyourchoice.     更高阶的静态网站生成器
gatsby
Gatsby 是一个为 React 打造的快如闪电的现代化站点生成器
官网：https://www.gatsbyjs.com/how-it-works/'><title>静态博客网站工具</title>

<link rel='canonical' href='https://www.walkingsky.top/p/%E9%9D%99%E6%80%81%E5%8D%9A%E5%AE%A2%E7%BD%91%E7%AB%99%E5%B7%A5%E5%85%B7/'>

<link rel="stylesheet" href="/scss/style.min.6e28907171ccdc82609ab6675872e3dc961a1b00f252b4d0a9299bde606269c3.css"><meta property='og:title' content='静态博客网站工具'>
<meta property='og:description' content='hexo 官方主页：https://hexo.io/zh-cn/
基于nodejs，部分主题对nodejs版本要求比较高，安装包升级包容易出现兼容性问题；
最大的问题就是编译速度太慢了。超过1W的文件量，windows底下就直接报“too many open files”错误，在linux下编译也是小时级别的，无法忍受。
找到的合适的主题：https://github.com/blinkfox/hexo-theme-matery
本地实施目录： F:\study\js\hexo_html 临时对比目录 F:\study\js\hexo2html
关于配置文件
根目录的配置文件和主题目录的配置文件一同生效，并且如果有相同配置，是以主题目录的配置为主的。这点试了好多次才发现的规律
遇到的问题：文件明太长，git无法cp文件，（windows文件名有255的长度限制）
报错信息：
1  unable to stat “xxxxxxxxxxxxxxxxxxx/index.html” Filename too long   解决方法：https://confluence.atlassian.com/bamkb/git-checkouts-fail-on-windows-with-filename-too-long-error-unable-to-create-file-errors-867363792.html
1 2  git config --system core.longpaths true git config --global core.longpaths true   hugo 官网文档：https://gohugo.io/getting-started/quick-start/
合适的主题：https://themes.gohugo.io/themes/parsa-hugo/
​	：文档：https://docs.gethugothemes.com/parsa/?ref=github
 另一个参考的主题：https://themes.gohugo.io/themes/hugo-theme-dream/ （问题多，而且demo和文档都无法查到了）  本地实施并修改的目录：
cloudflare上部署的时候遇到版本太低的问题，用环境变量来指定版本。官方文档说明如下
  1  Hugobuildsautomaticallyrunanoldversion.TorunthelatestversionofHugo(forexample,`0.80.0`),youwillneedtosetanenvironmentvariable.Set`HUGO_VERSION`to`0.80.0`ortheHugoversionofyourchoice.     更高阶的静态网站生成器
gatsby
Gatsby 是一个为 React 打造的快如闪电的现代化站点生成器
官网：https://www.gatsbyjs.com/how-it-works/'>
<meta property='og:url' content='https://www.walkingsky.top/p/%E9%9D%99%E6%80%81%E5%8D%9A%E5%AE%A2%E7%BD%91%E7%AB%99%E5%B7%A5%E5%85%B7/'>
<meta property='og:site_name' content='walkingsky的博客小站'>
<meta property='og:type' content='article'><meta property='article:section' content='Post' /><meta property='article:tag' content='静态网站' /><meta property='article:tag' content='hexo' /><meta property='article:tag' content='hugo' /><meta property='article:published_time' content='2022-02-14T01:19:16&#43;00:00'/><meta property='article:modified_time' content='2022-02-14T01:19:16&#43;00:00'/>
<meta name="twitter:title" content="静态博客网站工具">
<meta name="twitter:description" content="hexo 官方主页：https://hexo.io/zh-cn/
基于nodejs，部分主题对nodejs版本要求比较高，安装包升级包容易出现兼容性问题；
最大的问题就是编译速度太慢了。超过1W的文件量，windows底下就直接报“too many open files”错误，在linux下编译也是小时级别的，无法忍受。
找到的合适的主题：https://github.com/blinkfox/hexo-theme-matery
本地实施目录： F:\study\js\hexo_html 临时对比目录 F:\study\js\hexo2html
关于配置文件
根目录的配置文件和主题目录的配置文件一同生效，并且如果有相同配置，是以主题目录的配置为主的。这点试了好多次才发现的规律
遇到的问题：文件明太长，git无法cp文件，（windows文件名有255的长度限制）
报错信息：
1  unable to stat “xxxxxxxxxxxxxxxxxxx/index.html” Filename too long   解决方法：https://confluence.atlassian.com/bamkb/git-checkouts-fail-on-windows-with-filename-too-long-error-unable-to-create-file-errors-867363792.html
1 2  git config --system core.longpaths true git config --global core.longpaths true   hugo 官网文档：https://gohugo.io/getting-started/quick-start/
合适的主题：https://themes.gohugo.io/themes/parsa-hugo/
​	：文档：https://docs.gethugothemes.com/parsa/?ref=github
 另一个参考的主题：https://themes.gohugo.io/themes/hugo-theme-dream/ （问题多，而且demo和文档都无法查到了）  本地实施并修改的目录：
cloudflare上部署的时候遇到版本太低的问题，用环境变量来指定版本。官方文档说明如下
  1  Hugobuildsautomaticallyrunanoldversion.TorunthelatestversionofHugo(forexample,`0.80.0`),youwillneedtosetanenvironmentvariable.Set`HUGO_VERSION`to`0.80.0`ortheHugoversionofyourchoice.     更高阶的静态网站生成器
gatsby
Gatsby 是一个为 React 打造的快如闪电的现代化站点生成器
官网：https://www.gatsbyjs.com/how-it-works/">
    <link rel="shortcut icon" href="img/favicon.ico" />

    </head>
    <body class="
    article-page has-toc
">
    <script>
        (function() {
            const colorSchemeKey = 'StackColorScheme';
            if(!localStorage.getItem(colorSchemeKey)){
                localStorage.setItem(colorSchemeKey, "auto");
            }
        })();
    </script><script>
    (function() {
        const colorSchemeKey = 'StackColorScheme';
        const colorSchemeItem = localStorage.getItem(colorSchemeKey);
        const supportDarkMode = window.matchMedia('(prefers-color-scheme: dark)').matches === true;

        if (colorSchemeItem == 'dark' || colorSchemeItem === 'auto' && supportDarkMode) {
            

            document.documentElement.dataset.scheme = 'dark';
        } else {
            document.documentElement.dataset.scheme = 'light';
        }
    })();
</script>
<div class="container main-container flex 
    
        extended
    
">
    
        <div id="article-toolbar">
            <a href="/" class="back-home">
                <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-chevron-left" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round">
  <path stroke="none" d="M0 0h24v24H0z"/>
  <polyline points="15 6 9 12 15 18" />
</svg>



                <span>返回</span>
            </a>
        </div>
    
<main class="main full-width">
    <article class="main-article">
    <header class="article-header">

    <div class="article-details">
    

    <h2 class="article-title">
        <a href="/p/%E9%9D%99%E6%80%81%E5%8D%9A%E5%AE%A2%E7%BD%91%E7%AB%99%E5%B7%A5%E5%85%B7/">静态博客网站工具</a>
    </h2>

    

    
    <footer class="article-time">
        
            <div>
                <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-calendar-time" width="56" height="56" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round">
  <path stroke="none" d="M0 0h24v24H0z"/>
  <path d="M11.795 21h-6.795a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2h12a2 2 0 0 1 2 2v4" />
  <circle cx="18" cy="18" r="4" />
  <path d="M15 3v4" />
  <path d="M7 3v4" />
  <path d="M3 11h16" />
  <path d="M18 16.496v1.504l1 1" />
</svg>
                <time class="article-time--published">2022-02-14</time>
            </div>
        

        
            <div>
                <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-clock" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round">
  <path stroke="none" d="M0 0h24v24H0z"/>
  <circle cx="12" cy="12" r="9" />
  <polyline points="12 7 12 12 15 15" />
</svg>



                <time class="article-time--reading">
                    阅读时长: 1 分钟
                </time>
            </div>
        
    </footer>
    
</div>
</header>

    <section class="article-content">
    
    
    <h4 id="hexo">hexo</h4>
<p>官方主页：https://hexo.io/zh-cn/</p>
<p>基于nodejs，部分主题对nodejs版本要求比较高，安装包升级包容易出现兼容性问题；</p>
<p><!-- raw HTML omitted --><strong>最大的问题就是编译速度太慢了</strong><!-- raw HTML omitted -->。超过1W的文件量，windows底下就直接报“too many open files”错误，在linux下编译也是小时级别的，无法忍受。</p>
<p>找到的合适的主题：https://github.com/blinkfox/hexo-theme-matery</p>
<p>本地实施目录： F:\study\js\hexo_html  临时对比目录 F:\study\js\hexo2htm<strong>l</strong></p>
<p><strong>关于配置文件</strong></p>
<p>根目录的配置文件和主题目录的配置文件一同生效，并且如果有相同配置，是以主题目录的配置为主的。这点试了好多次才发现的规律</p>
<p><strong>遇到的问题</strong>：文件明太长，git无法cp文件，（windows文件名有255的长度限制）</p>
<p>报错信息：</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre tabindex="0" class="chroma"><code><span class="lnt">1
</span></code></pre></td>
<td class="lntd">
<pre tabindex="0" class="chroma"><code class="language-fallback" data-lang="fallback">unable to stat “xxxxxxxxxxxxxxxxxxx/index.html” Filename too long
</code></pre></td></tr></table>
</div>
</div><p>解决方法：https://confluence.atlassian.com/bamkb/git-checkouts-fail-on-windows-with-filename-too-long-error-unable-to-create-file-errors-867363792.html</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre tabindex="0" class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span></code></pre></td>
<td class="lntd">
<pre tabindex="0" class="chroma"><code class="language-fallback" data-lang="fallback">git config --system core.longpaths true
git config --global core.longpaths true
</code></pre></td></tr></table>
</div>
</div><h4 id="hugo">hugo</h4>
<p>官网文档：https://gohugo.io/getting-started/quick-start/</p>
<p>合适的主题：https://themes.gohugo.io/themes/parsa-hugo/</p>
<p>​			：文档：https://docs.gethugothemes.com/parsa/?ref=github</p>
<ul>
<li>另一个参考的主题：https://themes.gohugo.io/themes/hugo-theme-dream/ （问题多，而且demo和文档都无法查到了）</li>
</ul>
<p>本地实施并修改的目录：</p>
<p>cloudflare上部署的时候遇到版本太低的问题，用环境变量来指定版本。官方文档说明如下</p>
<ul>
<li>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre tabindex="0" class="chroma"><code><span class="lnt">1
</span></code></pre></td>
<td class="lntd">
<pre tabindex="0" class="chroma"><code class="language-mysql" data-lang="mysql"><span class="n">Hugo</span><span class="w"> </span><span class="n">builds</span><span class="w"> </span><span class="n">automatically</span><span class="w"> </span><span class="n">run</span><span class="w"> </span><span class="n">an</span><span class="w"> </span><span class="n">old</span><span class="w"> </span><span class="n">version</span><span class="p">.</span><span class="w"> </span><span class="k">To</span><span class="w"> </span><span class="n">run</span><span class="w"> </span><span class="n">the</span><span class="w"> </span><span class="n">latest</span><span class="w"> </span><span class="n">version</span><span class="w"> </span><span class="n">of</span><span class="w"> </span><span class="nf">Hugo</span><span class="w"> </span><span class="p">(</span><span class="k">for</span><span class="w"> </span><span class="n">example</span><span class="p">,</span><span class="w"> </span><span class="o">`</span><span class="mi">0</span><span class="p">.</span><span class="mi">80</span><span class="p">.</span><span class="mi">0</span><span class="o">`</span><span class="p">),</span><span class="w"> </span><span class="n">you</span><span class="w"> </span><span class="n">will</span><span class="w"> </span><span class="n">need</span><span class="w"> </span><span class="k">to</span><span class="w"> </span><span class="kt">set</span><span class="w"> </span><span class="n">an</span><span class="w"> </span><span class="n">environment</span><span class="w"> </span><span class="n">variable</span><span class="p">.</span><span class="w"> </span><span class="kt">Set</span><span class="w"> </span><span class="o">`</span><span class="n">HUGO_VERSION</span><span class="o">`</span><span class="w"> </span><span class="k">to</span><span class="w"> </span><span class="o">`</span><span class="mi">0</span><span class="p">.</span><span class="mi">80</span><span class="p">.</span><span class="mi">0</span><span class="o">`</span><span class="w"> </span><span class="k">or</span><span class="w"> </span><span class="n">the</span><span class="w"> </span><span class="n">Hugo</span><span class="w"> </span><span class="n">version</span><span class="w"> </span><span class="n">of</span><span class="w"> </span><span class="n">your</span><span class="w"> </span><span class="n">choice</span><span class="p">.</span><span class="w">
</span></code></pre></td></tr></table>
</div>
</div></li>
</ul>
<hr>
<p>更高阶的静态网站生成器</p>
<p><strong>gatsby</strong></p>
<p>Gatsby 是一个为 React 打造的快如闪电的现代化站点生成器</p>
<p>官网：https://www.gatsbyjs.com/how-it-works/</p>
<p>中文网站：https://www.gatsbyjs.cn/docs/</p>
<p><strong>gridsome</strong></p>
<p>基于 Vue.js 构建的 Jamstack 框架
Gridsome 让开发人员可以轻松地构建静态生成的网站和应用程序，这些网站和应用程序 天生速度快</p>
<p>官网：https://gridsome.org/</p>
<p>中文网站：https://www.gridsome.cn/</p>

</section>


    <footer class="article-footer">
    
    <section class="article-tags">
        
            <a href="/tags/%E9%9D%99%E6%80%81%E7%BD%91%E7%AB%99/">静态网站</a>
        
            <a href="/tags/hexo/">hexo</a>
        
            <a href="/tags/hugo/">hugo</a>
        
    </section>


    </footer>


    
        <link 
                rel="stylesheet" 
                href="https://cdn.jsdelivr.net/npm/katex@0.13.13/dist/katex.min.css"integrity="sha384-RZU/ijkSsFbcmivfdRBQDtwuwVqK7GMOw6IMvKyeWL2K5UAlyp6WonmB8m7Jd0Hn"crossorigin="anonymous"
            ><script 
                src="https://cdn.jsdelivr.net/npm/katex@0.13.13/dist/katex.min.js"integrity="sha384-pK1WpvzWVBQiP0/GjnvRxV4mOb0oxFuyRxJlk6vVw146n3egcN5C925NCP7a7BY8"crossorigin="anonymous"
                defer
                >
            </script><script 
                src="https://cdn.jsdelivr.net/npm/katex@0.13.13/dist/contrib/auto-render.min.js"integrity="sha384-vZTG03m&#43;2yp6N6BNi5iM4rW4oIwk5DfcNdFfxkk9ZWpDriOkXX8voJBFrAO7MpVl"crossorigin="anonymous"
                defer
                >
            </script><script>
    window.addEventListener("DOMContentLoaded", () => {
        renderMathInElement(document.querySelector(`.article-content`), {
            delimiters: [
                { left: "$$", right: "$$", display: true },
                { left: "$", right: "$", display: false },
                { left: "\\(", right: "\\)", display: false },
                { left: "\\[", right: "\\]", display: true }
            ]
        });})
</script>
    
</article>

    

    <aside class="related-contents--wrapper">
    
    
</aside>

     
    
        
    

    <footer class="site-footer">
    <section class="copyright">
        &copy; 
        
        2022 walkingsky的博客小站
    </section>
    
    <section class="powerby">
        
            <a href="https://beian.miit.gov.cn/" target="_blank">京ICP备2020035791号-2</a><br /> <a target="_blank" href="http://www.beian.gov.cn/portal/registerSystemInfo?recordcode=11010802038934" style="display:inline-block;text-decoration:none;height:20px;line-height:20px;"><img src="https://img.walkinginsky.com/blog/beian.png" style="float:left;"/><p style="float:left;height:20px;line-height:20px;margin: 0px 0px 0px 5px; color:#939393;">京公网安备 11010802038934号</p></a> <br/>
        Built with <a href="https://gohugo.io/" target="_blank" rel="noopener">Hugo</a> <br />
        Theme <b><a href="https://github.com/CaiJimmy/hugo-theme-stack" target="_blank" rel="noopener" data-version="3.8.0">Stack</a></b> designed by <a href="https://jimmycai.com" target="_blank" rel="noopener">Jimmy</a>
    </section>
</footer>


    
<div class="pswp" tabindex="-1" role="dialog" aria-hidden="true">

    
    <div class="pswp__bg"></div>

    
    <div class="pswp__scroll-wrap">

        
        <div class="pswp__container">
            <div class="pswp__item"></div>
            <div class="pswp__item"></div>
            <div class="pswp__item"></div>
        </div>

        
        <div class="pswp__ui pswp__ui--hidden">

            <div class="pswp__top-bar">

                

                <div class="pswp__counter"></div>

                <button class="pswp__button pswp__button--close" title="Close (Esc)"></button>

                <button class="pswp__button pswp__button--share" title="Share"></button>

                <button class="pswp__button pswp__button--fs" title="Toggle fullscreen"></button>

                <button class="pswp__button pswp__button--zoom" title="Zoom in/out"></button>

                
                
                <div class="pswp__preloader">
                    <div class="pswp__preloader__icn">
                        <div class="pswp__preloader__cut">
                            <div class="pswp__preloader__donut"></div>
                        </div>
                    </div>
                </div>
            </div>

            <div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">
                <div class="pswp__share-tooltip"></div>
            </div>

            <button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)">
            </button>

            <button class="pswp__button pswp__button--arrow--right" title="Next (arrow right)">
            </button>

            <div class="pswp__caption">
                <div class="pswp__caption__center"></div>
            </div>

        </div>

    </div>

</div><script 
                src="https://cdn.jsdelivr.net/npm/photoswipe@4.1.3/dist/photoswipe.min.js"integrity="sha256-ePwmChbbvXbsO02lbM3HoHbSHTHFAeChekF1xKJdleo="crossorigin="anonymous"
                defer
                >
            </script><script 
                src="https://cdn.jsdelivr.net/npm/photoswipe@4.1.3/dist/photoswipe-ui-default.min.js"integrity="sha256-UKkzOn/w1mBxRmLLGrSeyB4e1xbrp4xylgAWb3M42pU="crossorigin="anonymous"
                defer
                >
            </script><link 
                rel="stylesheet" 
                href="https://cdn.jsdelivr.net/npm/photoswipe@4.1.3/dist/default-skin/default-skin.css"integrity="sha256-c0uckgykQ9v5k&#43;IqViZOZKc47Jn7KQil4/MP3ySA3F8="crossorigin="anonymous"
            ><link 
                rel="stylesheet" 
                href="https://cdn.jsdelivr.net/npm/photoswipe@4.1.3/dist/photoswipe.css"integrity="sha256-SBLU4vv6CA6lHsZ1XyTdhyjJxCjPif/TRkjnsyGAGnE="crossorigin="anonymous"
            >

            </main>
    
        <aside class="sidebar right-sidebar sticky">
            <section class="widget archives">
                <div class="widget-icon">
                    <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-hash" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round">
  <path stroke="none" d="M0 0h24v24H0z"/>
  <line x1="5" y1="9" x2="19" y2="9" />
  <line x1="5" y1="15" x2="19" y2="15" />
  <line x1="11" y1="4" x2="7" y2="20" />
  <line x1="17" y1="4" x2="13" y2="20" />
</svg>



                </div>
                <h2 class="widget-title section-title">目录</h2>
                
                <div class="widget--toc">
                    <nav id="TableOfContents">
  <ol>
    <li>
      <ol>
        <li>
          <ol>
            <li><a href="#hexo">hexo</a></li>
            <li><a href="#hugo">hugo</a></li>
          </ol>
        </li>
      </ol>
    </li>
  </ol>
</nav>
                </div>
            </section>
        </aside>
    

        </div>
        <script 
                src="https://cdn.jsdelivr.net/npm/node-vibrant@3.1.5/dist/vibrant.min.js"integrity="sha256-5NovOZc4iwiAWTYIFiIM7DxKUXKWvpVEuMEPLzcm5/g="crossorigin="anonymous"
                
                >
            </script><script type="text/javascript" src="/ts/main.js" defer></script>
<script>
    (function () {
        const customFont = document.createElement('link');
        customFont.href = "https://fonts.googleapis.com/css2?family=Lato:wght@300;400;700&display=swap";

        customFont.type = "text/css";
        customFont.rel = "stylesheet";

        document.head.appendChild(customFont);
    }());
</script>

    </body>
</html>
